﻿using DesignPatterns.BuilderPattern.Core;
using DesignPatterns.BuilderPattern.Repositories;

namespace DesignPatterns.BuilderPattern.Config
{
    class DependencyInjectionConfig : ObjectFactoryModule
    {
        public override void Load()
        {
            //Repositories
            Bind<IPersonRepository>().To<PersonRepository>();
            Bind<IAddressRepository>().To<AddressRepository>();
            Bind<IPhoneNumberRepository>().To<PhoneNumberRepository>();
            Bind<IWebsiteRepository>().To<WebsiteRepository>();

            //Builder Repositories
            Bind<IPersonBuilder>().To<AddressRepository>();
            Bind<IPersonBuilder>().To<PhoneNumberRepository>();
            Bind<IPersonBuilder>().To<WebsiteRepository>();
        }
    }
}
